A memory leak is one of examples of system failure caused by a defect in software. A memory leak is a phenomenon in which an allocated memory for software objects or data is not released properly and a system shuts down due to exhaustion of a free area in the memory. In a general computer system, the memory is managed by an operating system (OS) and shared by a plurality of pieces of software. Thus, a defect in a piece of software sometimes causes a shutdown of the whole of the OS.
Recovering an OS which has shut down due to a memory leak requires a reboot of the computer system. In other words, it is required to turn off the computer system and boot the computer system again. In a case of a virtual machine achieved with a server virtualization function, it is required to remove a virtual machine which has shut down anomalously and newly generate a virtual machine again. In recovering an OS through reboot or regeneration, data not saved in a persistent storage, such as a hard disk, at the anomalous shutdown are deleted. In other words, data held in a non-persistent storage, such as a cache and a buffer, are deleted. As a consequence, not only data important for users but also information which becomes a clue to identify a cause of the anomalous shutdown are lost. Further, turning off the computer system which is in an anomalous condition causes inconsistency in data referenced by the software and sometimes makes it impossible to boot the computer system normally at reboot.
As described above, since such troubles are caused once a memory leak takes place, a method to avoid an occurrence of a memory leak in advance is employed in general.
A mobile terminal disclosed in PTL 1 monitors the operational status of an operating system at a constant time interval, and, when it is predicted that the operating system has become unstable due to a destabilizing factor, such as a memory leak, carries out a predetermined workaround corresponding to the predicted unstable condition. The mobile terminal disclosed in PTL 1 avoids an occurrence of a failure beforehand by carrying out such a measure.